package org.example.misc.utils;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;

public class DateUtils {
    private static final String COMMON_FORMAT_PATTERN = "yyyy-MM-dd HH:mm:ss";

    /**
     * LocalDateTime convert  yyyy-MM-dd HH:mm:ss
     */
    public static String dateToString(LocalDateTime localDateTime) {
        return localDateTime.format(DateTimeFormatter.ofPattern(COMMON_FORMAT_PATTERN));
    }
}
